ECHO OFF
BREAK ON
IF "%1"=="" GOTO USAGE
IF "%1"=="all" GOTO ALL
IF "%1"=="ALL" GOTO ALL
GOTO DIR
:ALL
FOR %%F IN (EXE2BIN CHKDSK COMMAND DEBUG DISKCOPY) DO COMMAND /C MK %%F %2 %3
FOR %%F IN (EDLIN FC FIND FORMAT MORE MSDOS PRINT) DO COMMAND /C MK %%F %2 %3
FOR %%F IN (RECOVER SORT SYS) DO COMMAND /C MK %%F %2 %3
GOTO END
:DIR
CD %1
MAKE OEM=%2 VER=%3 %1.MAK
CD ..
GOTO END
:USAGE
ECHO "Usage: MK [folder|ALL] [oem] [ver] (e.g., MK MSDOS IBM 200 or MK ALL)"
:END
